/*
*  LLLog_win32.cpp
*  
*
*  Created by Alexander Trutchenko on 11/02/12.
*  Copyright 2012 Free Team. All rights reserved.
*
*/

#include "lid_lib/src/service/LLLog.h"

#include <stdio.h>

#include <Windows.h>

namespace lidlib {

void LLLog(const char * pszFormat, ...)
{
    char szBuf[LL_MAX_LOG_LEN];

    va_list ap;
    va_start(ap, pszFormat);
    vsnprintf_s(szBuf, LL_MAX_LOG_LEN, LL_MAX_LOG_LEN, pszFormat, ap);
    va_end(ap);

    WCHAR wszBuf[LL_MAX_LOG_LEN] = {0};
    MultiByteToWideChar(CP_UTF8, 0, szBuf, -1, wszBuf, sizeof(wszBuf));
    OutputDebugStringW(wszBuf);
    OutputDebugStringA("\n");
}

} // namespace lidlib